package org.javaboy.demo.service;

import org.javaboy.demo.dao.UserDao;

public class UserService {

    UserDao userDao;

    public void setUserDao(UserDao userDao) {
        this.userDao = userDao;
    }

    public void transferMoney(String from, String to, Double money) {
        userDao.minusMoney(from, money);
        int i = 1 / 0;
        userDao.addMoney(to, money);
    }
}
